import { postAction, getAction, postUpload } from './request'


//登录
const ApiLogin = (params) => postAction("/api/login", params);
//退出
const ApiLogout = (params) => getAction("/api/logout", params);
//主页面展示
const ApiHome = (params) => getAction("/api/home", params);
//获取用户
const Apiuserlist = (params) => postAction("/api/userlist", params);
//改变用户状态
const ApiuserlistStatus = (params) => postAction("/api/userlist/status", params);
//删除用户
const ApiuserlistDelete = (params) => postAction("/api/userlist/delete", params);
//增加用户
const ApiAddUser = (params) => postAction("/api/userlist/adduser", params);
//模糊查询用户
const ApiLikeuser = (params) => postAction("/api/userlist/likeuser", params);
//用户重置密码
const ApiSetpassword = (params) => postAction("/api/userlist/setpassword", params);
//上传头像
// const ApiAvatarUpload = (params) => postUpload("/api/userlist/avatarUpload", params);
//用户登录日志
const ApiUserLog = (params) => postAction("/api/userlog", params);
//角色列表
const ApiPowerRoles = (params) => getAction("/api/power/roles", params);
//增加角色
const ApiPoweraddRoles = (params) => postAction("/api/power/addroles", params);
//删除角色
// const ApiPowerdelRoles = (params) => postAction("/api/power/delroles", params);
//获取admin
const ApiPoweradmin = (params) => getAction("/api/power/admin", params);
//获取admin
const ApiPoweraddadmin = (params) => postAction("/api/power/admin/addadmin", params);
//删除admin账号
const ApiPowerdeladmin = (params) => postAction("/api/power/admin/deladmin", params);
//根据admin账号查询权限
const ApiPowerrolesQX = (params) => postAction("/api/power/admin/rolesQX", params);
//给账号分配权限
const ApiPowerrolesqxFP = (params) => postAction("/api/power/admin/rolesqxFP", params);
//管理员账号重置密码
const ApiAdminSetpassword = (params) => postAction("/api/power/admin/setpassword", params);
//获取邮箱配置
const ApiThirdMail = (params) => getAction("/api/third/mail", params);
//保存邮箱设置
const ApiThirdSetmail = (params) => postAction("/api/third/setmail", params);
//保存邮箱选项设置
const ApiThirdSetmailOption = (params) => postAction("/api/third/setmailoption", params);
//测试发送邮箱
const ApiThirdsendEmail = (params) => postAction("/api/third/sendEmail", params);
//即时通讯
const ApiChat = (params) => postAction("/api/chat", params);
//站点查询
const ApiVersionGet = (params) => getAction("/api/version/get", params);
//新建站点
const ApiVersionSet = (params) => postAction("/api/version/set", params);
//删除站点
const ApiVersionDel = (params) => postAction("/api/version/del", params);
//获取路径
const ApiVersionGeturl = (params) => postAction("/api/version/geturl", params);
//删除文件详情文件
const ApiVersionDelfile = (params) => postAction("/api/version/delfile", params);
//解压文件
const ApiVersionUnzip = (params) => postAction("/api/version/Unzip", params);
//上传文件
const ApiVersionUpload = (params, config) => postUpload("/api/version/upload", params, config);
//验证码
const ApiGetCaptcha = (params) => getAction("/api/getCaptcha", params);
export {
    ApiLogin,
    ApiLogout,
    ApiHome,
    Apiuserlist,
    ApiuserlistStatus,
    ApiuserlistDelete,
    ApiAddUser,
    ApiLikeuser,
    ApiSetpassword,
    // ApiAvatarUpload,
    ApiUserLog,
    ApiPowerRoles,
    ApiPoweraddRoles,
    ApiPowerdelRoles,
    ApiPoweradmin,
    ApiPoweraddadmin,
    ApiPowerdeladmin,
    ApiPowerrolesQX,
    ApiPowerrolesqxFP,
    ApiAdminSetpassword,
    ApiThirdMail,
    ApiThirdSetmail,
    ApiThirdSetmailOption,
    ApiThirdsendEmail,
    ApiChat,
    ApiVersionGet,
    ApiVersionDel,
    ApiVersionSet,
    ApiVersionGeturl,
    ApiVersionDelfile,
    ApiVersionUnzip,
    ApiVersionUpload,
    ApiGetCaptcha
}